package com.authine.cloudpivot.ext.enums.finance;

/**
 * 付款状态
 */
public enum PaymentStatusEnum {

    /**
     *
     */
    ALL("0", "全部"),
    UNDO("1", "未开票"),
    DOING("2", "开票中"),
    DONE("3", "已开票");;

    public String id;
    public String text;

    private PaymentStatusEnum(String id, String text) {

        this.id = id;
        this.text = text;
    }

    public static PaymentStatusEnum get(String code) {

        for (PaymentStatusEnum c : PaymentStatusEnum.values()) {
            if (c.id.equals(code)) {
                return c;
            }
        }
        return null;
    }
}
